package com.hz.house.dao;
/**
 * 楼盘详情mapper
 * @author lfw
 *
 */


import java.util.List;
import java.util.Map;

import com.hz.house.bean.entity.*;
import org.apache.ibatis.annotations.Param;

import com.hz.house.bean.vo.BuildingDecoVo;
import com.hz.house.bean.vo.BuildingNumAndDecoVo;
import com.hz.house.bean.vo.ProjectInfo;
import com.hz.house.bean.vo.SimpleDataBean;
import com.hz.house.bean.vo.VerifyYaoHaoVo;

public interface BuildingDetailMapper {

	
	/**查询楼盘详细的基础信息*/
	BuildingBasicBean getBaseInfo(@Param("buildingId")int buildingId);
	
	List<BuildingMatchBean> getSubwayInfo(@Param("buildingId")int buildingId);
	
	String getDecorateInfo(@Param("buildingId") int buildingId);
	
	List<String> getImages(@Param("buildingId") int buildingId);
	
	List<BuildingDynmicBean> getLastDynamicInfo(@Param("buildingId")int buildingId);
	
	int getIsfocus(@Param("buildingId") int buildingId,@Param("customerId")int customerId);
	
	int getIsCollect(@Param("type")String type,@Param("buildingId")int buildingId,@Param("customerId")int customerId);
	
	List<OpenInfoBean> getAllOpenInfo(@Param("buildingId")int buildingId);
	
	/**
	 * 查询该楼盘所有开盘记录的文档资料
	 */
	List<OpenDocumetBean> getAllDocuMents(List<OpenInfoBean> openInfos);
	
	List<OpenHouseSuplus> getOpenHouseSuplus(List<OpenInfoBean> openInfos);

	
	List<YaoHaoResultBindBean> getUserAllBinds(@Param("nowKaiPan")List<OpenInfoBean> nowKaiPan,@Param("customerId")int customerId);
	
	List<VerifyYaoHaoVo> getHasYaoHaoResult(List<OpenInfoBean> kps);
	
	List<BuildingCommentBean> getBuildingDetailComments(@Param("buildingId")Integer buildingId
			,@Param("uid")Integer uid);
	
	List<BuildingCommentReply> getCommentReply(List<BuildingCommentBean> cms);
	
	List<BuildingCompetitor> getCompetitor(@Param("buildingId")int buildingId);
	
	List<BuildingInformationBean> getBuildingInformation(@Param("buildingId")int buildingId);
	
	BuildingCommentBean getDefaultComment(@Param("id")int id,@Param("uid")int customerId);
	
	List<SaleManBean> getSaleManV2_1(@Param("buildingId")int buildingId,@Param("limitDate")int limitDate);
	
	List<SaleManBean> getSaleMan(@Param("buildingId")int buildingId);
	
	List<BuildingImgBean> getAllBuildingImg(@Param("buildingId")int buildingId);
	
	List<BuildingHouseModelBean> getHouseModel(@Param("buildingId")int buildingId);
	List<BuildingHouseModelBean> getHouseModelV2_2(@Param("buildingId")int buildingId);
	
	List<BuildingDecoVo> getDecoPaln(@Param("orderNum")String orderNum);
	
	List<BuildingNumAndDecoVo> getBuildingNum(@Param("orderNum")String orderNum);
	
	List<HousePriceBean> searchHousePrice(Map<String,Object> m);
	
	int searchHosePriceTotal(Map<String,Object> m);
	
	List<BuildingCommentBean> getCommentByPage(@Param("buildingId")Integer buildingId
			,@Param("page")Integer page,@Param("uid")Integer uid);
	
	int getCommentsTotal(@Param("buildingId")Integer buildingId);
	
	void synVisits(List<SimpleDataBean> ds);
	
	int addBuildingComment(BuildingCommentBean comment);
	
	int addCommentReply(BuildingCommentReply reply);
	
	int addPraiseData(BuildingCommentPraiseBean praise);
	
	int deletePraiseData(BuildingCommentPraiseBean praise);
	
	Integer getReplyerId(int replyId);
	
	Integer getCommenterId(int commentId);
	
	String getSellManNameByid(int sellManCustomerId);
	
	String getUserNameByid(int customerId);
	
	BuildingCommentBean getCommentById(int commentId);
	
	int addNotifyRecord(BuildingNotifyRecord r) throws Exception;
	
	int deleteNotifyRecord(BuildingNotifyRecord r);

    List<BuildingInformationBean> getBuildingInformationV2_2(@Param("buildingId") Integer buildingId, @Param("type") Integer type);

    ProjectInfo getProjectInfo(@Param("orderNum")String orderNum);
    
    
    String getBuildingName(int buildingId);

	List<BuildingDynamic> getBuildingDyn(@Param("buildingId") Integer buildingId,@Param("page") Integer page,@Param("size") Integer size);

	Integer getBuildingDynTotal(Integer buildingId);

    BuildingBasicBean getBuildingBillBean(Integer buildingId);

	List<BuildingDiscount> getDiscount(@Param("date") String date);

    String getYhTitle(@Param("buildingId") Integer buildingId,@Param("date") String date);

    Integer getDiscountTotal(Integer buildingId);

    List<BuildingDiscount> getDiscounts(@Param("page") int page,@Param("size") int size,@Param("buildingId") Integer buildingId);
}
